<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%--
  Created by IntelliJ IDEA.
  User: 26383
  Date: 2020/12/15
  Time: 13:17
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%
    String path = request.getContextPath();
    String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>

<div class="layui-side layui-bg-black">
    <div class="layui-side-scroll">
        <!-- 左侧导航区域（可配合layui已有的垂直导航） -->
        <ul class="layui-nav layui-nav-tree"  lay-filter="test">
            <li class="layui-nav-item layui-nav-itemed">
                <a>新闻类别</a>
                <dl class="layui-nav-child">
                    <dd><a href="<%=basePath%>/admin/index.jsp;">所有新闻</a></dd>
                    <c:forEach var="cate" items="${sessionScope.categories}">
                         <dd><a href="/FindByCate?category=${cate.category}">${cate.category}</a></dd>
                    </c:forEach>
                </dl>
            </li>
            <li class="layui-nav-item">
                <a href="javascript:;">类别管理</a>
                <dl class="layui-nav-child">
                    <dd><a href="<%=basePath%>/admin/showcategorieslist.jsp">显示所有类别</a></dd>
                    <dd><a href="<%=basePath%>/admin/cateadd.jsp">添加新闻类别</a></dd>
                </dl>
            </li>
            <li class="layui-nav-item"><a href="<%=basePath%>/admin/showAdmininfo.jsp">管理员信息</a></li>
        </ul>
    </div>
    </div>
